<section id="home-hero" class="hero-banner">
  <div class="container my-4 my-md-5">
    <div class="row">
      <div class="col-sm-12">
        <h1 class="page-title" id="contentStart" tabindex="-1" translate>home.title</h1>

        <p class="lead">
          OrgBook BC is a searchable public directory of open verifiable data about organizations legally registered in
          BC.
        </p>
      </div>
    </div>

    <loading-indicator [loading]="!inited" class="dark-bg"></loading-indicator>

    <div class="row mt-3 mt-md-4" *ngIf="inited">
      <div class="col-sm-10 col-lg-8">
        <label class="h3 search-title mb-3" for="queryInput" translate>search.title</label>
        <search-input
          #searchInput
          (accepted)="performSearch($event)"
          class="dark-bg"
          showInactive="true"
          (credTypeChange)="setCredType($event)"
          textColour='text-white'
        ></search-input>
      </div>
    </div>
  </div>
</section>

<section id="home-body" class="container">
  <div class="row mt-4 mt-md-5">
    <div class="col-md-7 col-lg-8">
      <h2 translate>home.about-title</h2>

      <p class="mt-3">
        This new service uses cutting-edge blockchain-based technology, which provides the foundation to help BC move to
        a digital economy.
      </p>

      <p>
        OrgBook BC supports our goal to streamline and modernize services for British Columbians as part of our broader
        Digital Government Strategy.
      </p>

      <p>
        Right now, you can use OrgBook BC to quickly verify if an organization is legally registered to do business in
        BC as a corporation. You can also find "Doing Business as" names registered by corporations.
      </p>

      <p>
        In the future, verifiable data about other organizations types such as sole proprietors and societies will be
        added. As well, other important verifable data such as the permits, licenses, and other accreditations these
        organizations hold will be added to OrgBook BC.
      </p>
    </div>
    <div class="col-md-5 col-lg-4">
      <div class="alert alert-danger" *ngIf="loadError">
        {{ 'general.other-error' | translate }}
      </div>
      <div class="card card-primary" *ngIf="inited && !loadError">
        <div class="card-header">
          <h2 class="h4 my-0">Current Statistics</h2>
        </div>
        <div class="card-body">
          <div class="stat-row">
            <span class="square text-number">{{ recordCounts.registrations | shortNumber }}</span>
            <span class="desc">{{ 'home.title-orgs' | translate }}</span>
          </div>
          <div class="stat-row">
            <span class="square text-number">{{ recordCounts.active | shortNumber }}</span>
            <span class="desc">{{ 'home.title-certs' | translate }}</span>
          </div>
          <div class="stat-row">
            <span class="square text-number">{{ recordCounts.last_week | shortNumber }}</span>
            <span class="desc">{{ 'home.title-this-week' | translate }}</span>
          </div>
        </div>
      </div>
    </div>
  </div>
</section>

<section id="home-testimonials" class="container">
  <div class="mt-4 mt-md-5 mx-1">
    <h3 class="mb-4">What they say about us</h3>

    <div class="row mx-1">
      <a href="https://www.cfib-fcei.ca/" class="col mt-2 d-none d-lg-block">
        <img
          [src]="'assets/img/logos/cfib_logo.jpg'"
          width="80"
          height="80"
          tabindex="-1"
          alt="Canadian Federation of Independent Businesses"
        />
      </a>
      <blockquote class="col-md-7 col-lg-10 blockquote font-italic text-justify">
        <p>
          <small>
            We have been a champion of small businesses for nearly 50 years and one of the top concerns from our members
            is red tape when complying with government paperwork, B.C. entrepreneurs will appreciate the simplicity
            OrgBook BC has to offer and any time and effort it will save.
          </small>
        </p>
        <footer class="blockquote-footer">
          <small>
            Richard Truscott,
            <cite title="Source Title"
              >vice-president, B.C. and Alberta, Canadian Federation of Independent Business</cite
            >
          </small>
        </footer>
      </blockquote>
    </div>

    <hr />

    <div class="row mx-1">
      <blockquote class="col-md-7 col-lg-10 blockquote font-italic text-justify">
        <p>
          <small>
            In a data-driven, hyperconnected and digital world, businesses need a comprehensive system for trustworthy
            verification of other entities digital identity. British Columbia’s Verifiable Organizations Network will
            empower businesses with a trusted digital identity issued by their local government. This is a prerequisite
            for digital optimization in the Fourth Industrial Revolution.
          </small>
        </p>
        <footer class="blockquote-footer">
          <small>
            Nadia Hewett,
            <cite title="Source Title"
              >Project Lead for Blockchain, World Economic Forum, Centre for the Fourth Industrial Revolution</cite
            >
          </small>
        </footer>
      </blockquote>
      <a href="https://www.weforum.org/" class="col mt-2 d-none d-lg-block">
        <img
          [src]="'assets/img/logos/World_Economic_Forum_logo.svg'"
          width="120"
          height="120"
          tabindex="-1"
          alt="World Economic Forum Logo"
          class="float-right"
        />
      </a>
    </div>
  </div>
</section>
